package com.example.p346namedquerymethod.repository;

import com.example.p346namedquerymethod.model.Course;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface CourseRepository extends CrudRepository<Course, Long> {

    Iterable<Course> findAllByCategoryAndRating(String category, int rating);

    Iterable<Course> findAllByRating(int rating);
}

